<template name="afImageGallery">
  <div class="af-image-gallery-input">

    <!-- Image collection -->
    <div class="images">
      {{#each images}}
      {{> afImageGalleryImage }}
      {{/each}}
    </div>

    <!-- Actual input (hidden) -->
    <input type="hidden" class="image-value" value="{{selectedValue}}" data-schema-key="{{schemaKey}}" />
  </div>
</template>

<template name="afImageGalleryImage">
  <div class="image {{isSelected}}">
    <img src="{{url}}" />
  </div>
</template>
